//
//  TopMovieCell.m
//  MtimeMovie
//
//  Created by lllyyy on 15/7/22.
//  Copyright (c) 2015年 lllyyy. All rights reserved.
//

#import "TopMovieCell.h"
#import "UIImageView+WebCache.h"
@implementation TopMovieCell

- (void)awakeFromNib {
    // Initialization code
}
- (void)setModal:(MovieModel *)modal{
    _modal = modal;
    [self setNeedsLayout];
}

- (void)layoutSubviews{
    [super layoutSubviews];
    NSString *str = [_modal.images objectForKey:@"medium"];
    [_imageView sd_setImageWithURL:[NSURL URLWithString:str]];
    _starView.average = _modal.average;
    _titleLabel.text = _modal.title;
    _avergerLabel.text = [NSString stringWithFormat:@"%.1f",_modal.average];
}

    
@end
